﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

public partial class Admin_SessionTimeOut : System.Web.UI.Page
{
    public int SessionTime;
    protected void Page_Load(object sender, EventArgs e)
    {
        SessionTime = CallSession();
        Response.Write(SessionTime.ToString());
    }
    private int CallSession() { 
        /*danh sach cac session can phai goi*/
       /*Khai bao 1 bien de  chua all cac session nay*/
        try
        {
            int restul = 0;
            string[] ArrSession = { Session["username"].ToString(), Session["customer"].ToString(), Session["loginurl"] .ToString(),Session["popup"].ToString()};
            int n = ArrSession.Length;
            for (int i = 0; i < n; i++) {
                if (ArrSession[i].ToString() != "")
                    restul = 1;
            }
            return restul;
        }
        catch {
            return 0;
        }
    }
}
